<?php

/**
 * Created by PhpStorm.
 * User: linux
 * Date: 15/01/2018
 * Time: 12:55 PM
 */
namespace IoC\SuperMan;

use IoC\Weapon\Fire;

class SuperMan
{
    protected $weapon = null;

    public function __construct(Fire $fireWeapon)
    {
        $this->weapon = $fireWeapon;
    }

    /**
     * 武器发射
     */
    public function fire()
    {
        $this->weapon->doFire(1);
    }

}